/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.mycompany.pagoxusuario.entidades;

import java.io.Serializable;
import javax.persistence.Cacheable;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import javax.validation.constraints.NotNull;

/**

 */
@Entity
@Cacheable
public class Pago implements Serializable {
	
	private static final long serialVersionUID = -2662121846406869911L;
	
	@Id @GeneratedValue
	private Long id1;
        private Long id2;
        private String periodo;
	@NotNull(message="La resolucion del pago no puede ser nulo")
	private String resolucion;
    	
        
            
     	@Override
	public String toString() {
		return resolucion;
	}
	
	public Long getId1() {
		return id1;
	}
	public void setId1(Long id1) {
		this.id1 = id1;
	}

        public Long getId2() {
		return id2;
	}
	public void setId2(Long id21) {
		this.id2 = id2;
	}

        
        
        public String getResolucion() {
        return resolucion;
        }

        public void setResolucion(String resolucion1) {
        this.resolucion = resolucion;
            }

     
        public String getPeriodo() {
        return periodo;
          }
   
    public void setPeriodo(String periodo) {
        this.periodo = periodo;
    }

           
@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (!(obj instanceof Pago))
			return false;
		Pago other = (Pago) obj;
		if (id1 == null) {
			if (other.id1 != null)
				return false;
		} else if (!id1.equals(other.id1))
			return false;
		return true;
	}

}
	
